package dbStruct;

import edu.umd.cs.piccolo.PNode;

public class Connector {
	public static enum RelationType{NONE,ATTRIBUTE,RELATION,GENERALIZATION};
	public static enum Cardinality{NONE,ONE2ONE,ONE2MANY,MANY2ONE,MANY2MANY};
	private Node source;
	private Node destination;
	private PNode pnode;
	private RelationType relType;
	private Cardinality  cardinality;
	
	public Connector(Node source, Node destination, RelationType relation, Cardinality cardinality){
		super();
		this.source=source;
		this.destination=destination;
		this.relType=relation;
		this.cardinality=cardinality;
	}

	public Node getSource() {
		return source;
	}

	public void setSource(Node source) {
		this.source = source;
	}

	public Node getDestination() {
		return destination;
	}

	public void setDestination(Node destination) {
		this.destination = destination;
	}

	public RelationType getRelationType() {
		return relType;
	}

	public void setRelationType(RelationType relType) {
		this.relType = relType;
	}

	public Cardinality getCardinality() {
		return cardinality;
	}

	public void setCardinality(Cardinality cardinality) {
		this.cardinality = cardinality;
	}
	public PNode getPNode()	{
		return this.pnode;
	}
	public void setPNode(PNode node){
		this.pnode=node;
	}
	
}
